<meta http-equiv="Content-Type" content="text/html; charset=utf8">
<LINK REL="stylesheet" HREF="../../templates/css/style.css" TYPE="text/css">
<LINK rel="stylesheet" href="../../templates/css/dialog.css" type="text/css">
<script language="javascript" src="../../templates/js/tab.js"></script>
<script language="javascript" type="text/javascript" src="../../lib/cate.js"></script>
<script language="javascript" type="text/javascript">
<!--
  var oTabs = new Object() ;
  
  function check_form()
  {
    var k = objSorts.childNodes.length;
	cur_num = k - 1;
    cur_list = document.getElementById("sel_" + cur_num);
	cur_value = cur_list.value;
	if (cate[cur_value] || cur_value == "")
	{
	  alert("請選擇分類!");
      SetSelectedTab("chinese");
	  return false;
	}
	if(document.add_news.address.value =="")
	{
	   alert("請輸入房屋位置!");
	   return false;
	}
	
	if(document.add_news.area.value == "")
	{
	   alert("請輸入坪數!");
	   return false;
	}

	if(document.add_news.title.value =="")
	{
	   alert("請輸入房屋名稱!");
	   return false;
	}	
	
	if(document.add_news.linkman.value == "")
	{
	   alert("請輸入聯絡人!");
	   return false;
	}
	
	
	if(document.add_news.price.value == "")
	{
	   alert("請輸入希望賣價!");
	   return false;
	}
	
	if(document.add_news.layout.value == "")
	{
	   alert("請輸入格局!");
	   return false;
	}
	
	if(document.add_news.flo1.value == "")
	{
	   alert("請輸入出售樓!");
	   return false;
	}

	if(document.add_news.flo2.value == "")
	{
	   alert("請輸入總樓層!");
	   return false;
	}
	
	if(document.add_news.age.value == "")
	{
	   alert("請輸屋齡!");
	   return false;
	}
	
	
	obj_form = document.add_news;
	obj_form.cate_id.value = cur_value;
	obj.submit;
  } //End fun
  function init_cate()
  {
     {init_cate}
  }  
function AddMoreRow() 
{ 
    var oRow=event.srcElement.parentNode.parentNode; 
    var oTable=oRow.parentNode.parentNode; 
    oNewRow=oTable.insertRow(); 
    for(i=0;i<oRow.cells.length;i++) 
    { 
        oNewRow.insertCell().innerHTML=oRow.cells[i].innerHTML; 
    } 
    oRow.all("DelBtn").disabled=false; 
    oNewRow.all("DelBtn").disabled=false; 
} 
function DeleteMoreRow() 
{ 
    var oRow=event.srcElement.parentNode.parentNode; 
    var oTable=oRow.parentNode.parentNode; 
   if(oTable.rows.length>1) 
    { 
        oTable.deleteRow(oRow.rowIndex); 
        if(oTable.rows.length==1) 
        { 
           oTable.all("DelBtn").disabled=true; 
        } 
    } 
} 
function DisabledKeyInput() 
{ 
    if(event.keyCode!=8&&event.keyCode!=46) 
    { 
        event.returnValue=false; 
    } 
} 


//多圖片上传代码
function add_inp(){ 
	newInp = document.createElement("input") 
	newInp.setAttribute("type","file") 
	newInp.setAttribute("name","upfile[]") 
	div1.appendChild(newInp) 
	newInp = document.createElement("br") 
	div1.appendChild(newInp) 
} 
function del_inp(){ 
	childlen=div1.childNodes.length 
	childlen-- 
	div1.removeChild(div1.childNodes[childlen]) 
	childlen-- 
	div1.removeChild(div1.childNodes[childlen]) 
} 
//-->
</script>
<table width="98%" border="0" class="table2">
  <tr>
    <td>管理中心 - 出租管理 - 出租房信息修改</td>
  </tr>
</table>
<form method="post" name="add_news" action="./modules/update_news.php" onsubmit="return check_form()" enctype="multipart/form-data" >
<table cellpadding=0 cellspacing=3 width=98% align="center" style="border:1px solid #A5ADC4">
  
<tr id="chinese">
<th colspan="2">
<table width="100%" border="0" cellspacing="2" cellpadding="2">
<tr>
  <td width="15%" align="right" ><strong>注意事項:</strong></td>
  <td width="85%"><textarea name="adminnotes" rows="5" cols="35">{adminnotes}</textarea></td>
</tr>
<tr>
  <td width="15%" align="right" ><b>產品分類:</b></td>
  <td width="85%"> {SHOW_CATE} </td>
</tr>

<tr>
  <td width="15%" align="right" ><b>分店選擇: </b></td>
  <td width="85%"> 
  <select name="store">{fd}</select>
  </td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>房屋編號:</strong></td>
  <td width="85%"><input name="num" type="text" value="{num}" readonly="readonly" size='40' /> *</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>房屋地址:</strong></td>
  <td width="85%"><input name="address" type="text" value="{address}" size='40' /> *</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>標題:</strong></td>
  <td width="85%"><input name="title" type="text" value="{title}" maxlength="20" size='40' /> *</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>大樓案名:</strong></td>
  <td width="85%"><input name="hou_name" type="text" value="{hou_name}" maxlength="20" size='40' /> *</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>坪數:</strong></td>
  <td width="85%"><input name="area" type="text" value="{area}" size='40' /> *</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>聯絡人:</strong></td>
  <td width="85%"><input name="linkman" type="text" value="{linkman}" size='40' /> *</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>電話:</strong></td>
  <td width="85%"><input name="tel" type="text" value="{tel}" size='40' /> </td>
</tr>

<tr>
  <td width="14%" align="right" ><strong>行動電話:</strong></td>
  <td width="86%"><input name="mobile" type="text" value="{mobile}" size='40' /> *</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>希望賣價:</strong></td>
  <td width="85%"><input name="price" type="text" value="{price}" size='40' /> *</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>優惠價:</strong></td>
  <td width="85%"><input name="sale" type="text" value="{sale}" size='40' />
  元</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>最優價:</strong></td>
  <td width="85%"><input name="min_sale" type="text" value="{min_sale}" size='40' />
    元</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>格局:</strong></td>
  <td width="85%"><input name="layout" type="text" value="{layout}" size='40' /> *</td>
</tr>
<tr>
  <td width="15%" align="right" ><strong>出售樓層/總樓層:</strong></td>
  <td width="85%"><input name="flo1" type="text" value="{flo1}" size='5' /> 樓(所在樓層) <input name="flo2" type="text" value="{flo2}" size='5' /> 樓(總樓高)*</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>屋齡</strong><b>:</b></td>
  <td width="85%"><input name="age" type="text" value="{age}" size='40' />  年 </td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>來源:</strong></td>
  <td width="85%"><input name="xx" type="text" value="{source}" size='40'  readonly="readonly"  /><br>
    {sourcexx} </td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>類型:</strong> </td>
  <td width="85%"><input name="xxx" type="text" value="{type}" size='40'  readonly="readonly"  /><br>
    {typexx}
  *</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>家電:</strong></td>
  <td width="85%">
  <textarea name="wiring2" rows="5" cols="40" readonly="readonly">{wiring}</textarea>
  <br>
    {wiringxx}</td>
</tr>


<tr>
  <td width="15%" align="right" ><strong>家具:</strong></td>
  <td width="85%">
  <textarea name="x0" rows="5" cols="40" readonly="readonly">{furniture}</textarea>
  <br>
    {furniturexx}</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>共設</strong><b>:</b></td>
  <td width="85%">
  <textarea name="x1" rows="5" cols="40" readonly="readonly">{fire}</textarea>
 <br>
    {firexx}</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>租金包含</strong><b>:</b></td>
  <td width="85%">
 <textarea name="x2" rows="5" cols="40" readonly="readonly">{baohang}</textarea><br>
    {baohangxx}</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>保全</strong><b>:</b></td>
  <td width="85%">
   <textarea name="x3" rows="5" cols="40" readonly="readonly">{baoquan}</textarea><br>
    {baoquanxx}</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>方位</strong><b>:</b></td>
  <td width="85%"><input name="x4" type="text" value="{position}" size='40'  readonly="readonly"  /><br>
    {positionxx}</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>電梯</strong><b>:</b></td>
  <td width="85%"><input name="x5" type="text" value="{elevator}" size='40'  readonly="readonly"  /><br>
    {elevatorxx}</td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>狀態</strong><b>:</b></td>
  <td width="85%"> <input name="del"  type="radio" value="0" {del1} />開啟
      <input name="del"  type="radio" value="1" {del2} >關閉
      </td>
</tr>

<tr>
  <td width="15%" align="right" ><strong>車位</strong><b>:</b></td>
  <td width="85%"> <input name="unit"  type="radio" value="有" {unit} />是
      <input name="unit"  type="radio" value="無" {unit2}>
      否
      <label for="Parking0">
      <input name="unit"  type="radio" value="可租" {unit3}/>
      可租</label></td>
</tr>

<tr>
  <td width="15%" align="right" ><b>本日精選: </b></td>
  <td width="85%"><input name="featureday"  type="radio" value="1" {featureday}/>是 
  <input name="featureday"  type="radio" value="0" {featureday2}/>否</td>
</tr>

<tr>
  <td width="15%" align="right" ><b>賣屋精選: </b></td>
  <td width="85%"><input name="feature"  type="radio" value="1" {feature}/>是 
  <input name="feature"  type="radio" value="0" {feature2}/>否</td>
</tr>

<tr>
  <td width="15%" align="right" ><b>特惠方案: </b></td>
  <td width="85%"><input name="saveplan"  type="radio" value="0" {saveplan}/>否
    <input name="saveplan"  type="radio" value="1" {saveplan1} />
    生活簡約型
    <input name="saveplan"  type="radio" value="2" {saveplan2}/>
    精緻高雅型
    <input name="saveplan"  type="radio" value="3" {saveplan3} />
    時尚尊貴型 </td>
</tr>

<tr>
  <td width="15%" align="right" ><b>店長推薦: </b></td>
  <td width="85%"><input name="recommended"  type="radio" value="1" {recommended} />是 
  <input name="recommended"  type="radio" value="0" {recommended2}/>否<br />
  <textarea cols="40" name="adminshow" rows="8">{adminshow}</textarea></td>
</tr>

<tr>
  <td width="15%" align="right" valign="top" ><b>特色: </b></td>
  <td width="85%">{tese}</td>
</tr>

<tr>
  <td width="15%" align="right" valign="top" ><b>GOOGLED地圖: </b></td>
  <td width="85%">
  <textarea cols="40" name="map" rows="8">{map}</textarea>
  </td>
</tr>


 <tr>
	<th width="15%" align="right">首頁圖片</th>
	<td width="85%">{img}<input type="file" name="img" size='40'  /> </td>
  </tr>
  
<tr>
	<th width="15%" align="right">圖一</th>
	<td width="85%">{img1}<input type="file" name="img1" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖二</th>
	<td width="85%">{img2}<input type="file" name="img2" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖三</th>
	<td width="85%">{img3}<input type="file" name="img3" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖四</th>
	<td width="85%">{img4}<input type="file" name="img4" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖五</th>
	<td width="85%">{img5}<input type="file" name="img5" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖六</th>
	<td width="85%">{img6}<input type="file" name="img6" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖七</th>
	<td width="85%">{img7}<input type="file" name="img7" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖八</th>
	<td width="85%">{img8}<input type="file" name="img8" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖九</th>
	<td width="85%">{img9}<input type="file" name="img9" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖十</th>
	<td width="85%">{img10}<input type="file" name="img10" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖十一</th>
	<td width="85%">{img11}<input type="file" name="img11" size='40'  /> </td>
</tr>

<tr>
	<th width="15%" align="right">圖十二</th>
	<td width="85%">{img12}<input type="file" name="img12" size='40'  /> </td>
</tr>
<tr>
   <td colspan="2"><div align="left" style="padding-left:150px;">
    <input type="hidden" name="id" value="{id}" />
  <input type="hidden" name="cate_id" value="" /><input type="hidden" name="news_id" value="{news_id}" />
  <input name="btn_sub" type="submit" id="btn_sub" value="確 定" class="bot" />
  <input name="reset" type="reset" id="reset" value="重 置" class="bot" />
  <input name="btn_ret" type="button" id="btn_ret" value="返 回" onclick="location.href='?action=news'" class="bot" />
    </div></td>
  </tr>
  </table>
  </th>
</tr>
 </table>
 <br>
</form>

<script type="text/javascript" language="javascript">
<!--
   init_cate();
//-->
</script>
